package com.business.business.web.web;

import cn.hutool.json.JSONObject;
import com.business.business.common.base.BaseController;
import com.business.business.support.annotaion.Action;
import com.business.business.support.annotaion.At;
import com.business.business.support.model.RespEntity;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @Author: YangYu
 * @ClassName: ListeningController
 * @Date: Created in 16:09 2021/7/22
 * @Description: 服务器监听
 */
@Action
@RequestMapping("server")
public class ListeningController extends BaseController {

    @At(value = "listening", method = RequestMethod.POST)
    public RespEntity python(@RequestBody(required = false) JSONObject jsonParam) throws Exception  {
        System.out.println(jsonParam.getStr("Listening"));
        return RespEntity.success();
    }
}
